home *** CD-ROM | disk | FTP | other *** search
/ NeXTSTEP 3.3 (Developer)…68k, x86, SPARC, PA-RISC] / NeXTSTEP 3.3 Dev Intel.iso / usr / sybase / doc / dbaltcolid.man < prev    next >
Text File  |  1993-04-22  |  2KB  |  67 lines

  1.  
  2.   1                       Version 4.0 -- 5/1/89               dbaltcolid
  3.   ______________________________________________________________________
  4.  
  5.   NAME:  dbaltcolid
  6.  
  7.   FUNCTION:
  8.        Return the column id for a compute column.
  9.  
  10.   SYNTAX:
  11.        int dbaltcolid(dbproc, computeid, column)
  12.  
  13.        DBPROCESS *dbproc;
  14.        int       computeid;
  15.        int       column;
  16.  
  17.  
  18.  
  19.  
  20.  
  21.  
  22.  
  23.  
  24.   dbaltcolid              Version 4.0 -- 5/1/89                        2
  25.   ______________________________________________________________________
  26.  
  27.   COMMENTS:
  28.  
  29.        o This routine returns the select-list id for a  compute  column.
  30.          For example, given the SQL statement:
  31.  
  32.               select dept, name from employee
  33.                 order by dept, name
  34.                 compute count(name) by dept
  35.  
  36.          the call dbaltcolid(dbproc, 1, 1) will return 2, since name  is
  37.          the second column in the select-list.
  38.  
  39.   PARAMETERS:
  40.        dbproc -  A pointer to the DBPROCESS structure that provides  the
  41.            connection for a particular front end/SQL Server process.  It
  42.            contains all the information that DB-Library uses  to  manage
  43.            communications and data between the front end and SQL Server.
  44.  
  45.  
  46.   3                       Version 4.0 -- 5/1/89               dbaltcolid
  47.   ______________________________________________________________________
  48.        computeid -  The id that identifies the particular compute row of
  49.            interest.   A  SQL SELECT statement may have multiple COMPUTE
  50.            clauses, each of which returns a separate compute  row.   The
  51.            computeid  corresponding  to  the  first  COMPUTE clause in a
  52.            SELECT is 1.  The computeid is  returned  by  dbnextrow()  or
  53.            dbgetrow().
  54.        column -  The number of the  compute  column  of  interest.   The
  55.            first column in a select-list is 1.
  56.  
  57.   RETURNS:
  58.        The select-list id for the compute column.  The first column in a
  59.        select-list  is  1.   If  either  the computeid or the column are
  60.        invalid, dbaltcolid() returns -1.
  61.  
  62.   SEE ALSO:
  63.        dbadata,  dbadlen,  dbaltlen,  dbgetrow,  dbnextrow,   dbnumalts,
  64.        dbprtype
  65.  
  66.  
  67.